/*
 * SonarQube
 * Copyright (C) 2009-2021 SonarSource SA
 * mailto:info AT sonarsource DOT com
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 3 of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 */
.snippet {
  margin: var(--gridSize);
  border: 1px solid var(--gray80);
  overflow-x: auto;
  overflow-y: hidden;
  transition: max-height 0.2s;
}

.snippet > div {
  display: table;
  width: 100%;
  position: relative;
  transition: margin-top 0.2s;
}

.snippet table {
  width: 100%;
}

.expand-block {
  position: absolute;
  z-index: 2;
  width: 100%;
}

.expand-block > button {
  background: transparent;
  box-sizing: border-box;
  color: var(--secondFontColor);
  height: 20px;
  width: 100%;
  padding: calc(var(--gridSize) / 4);
  border: 0;
  text-align: left;
  cursor: pointer;
}

.expand-block > button:hover,
.expand-block > button:focus,
.expand-block > button:active {
  color: var(--darkBlue);
  outline: none;
}

.expand-block-above {
  background: url('');
  top: 0;
}

.expand-block-below {
  background: url('');
  bottom: 0;
}

.source-table.expand-up {
  margin-top: 20px;
}

.source-table.expand-down {
  margin-bottom: 20px;
}
